package com.dashan.register;

import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

import com.dashan.service.impl.HelloServiceImpl;

/**
 * 用于注册发现服务
 * @author b5m
 *
 */
public class ServiceRegister {

	private static Map<String, Object> serviceProvider = new ConcurrentHashMap<>();
	
	static {
		serviceProvider.put("com.dashan.service.HelloService", new HelloServiceImpl());
	}
	
	public static Object getServiceByName(String name) {
		return serviceProvider.get(name);
	}
}
